package cn.edu.scau.cmi.yeshaoying.composite.consistent;

import java.util.Set;

public class ConsistentLeaf implements ConsistentComponent {
	private String name;
	private ConsistentComponent parent;
	
	public ConsistentLeaf(String a) {
		this.name = a;
	}
	
	public void addP(ConsistentComponent c) {
		this.parent = c;
	}

	@Override
	public String doSomething() {
		return this.name;
	}

	@Override
	public ConsistentComponent getParent() {
		return this.parent;
	}

	@Override
	public void addChild(ConsistentComponent c) {

	}

	@Override
	public void delete(ConsistentComponent child) {

	}

	@Override
	public Set<ConsistentComponent> getChildren() {
		return null;
	}

	@Override
	public void updateChildren(Set<ConsistentComponent> childrenSet) {

	}

}
